import java.io.FileReader;
import java.io.IOException;
import java.io.Reader;

/**
 * @Author YuanYuan
 * @Date 2022/10/7
 * @Time 15:41
 */
public class Demo9 {
    //使用字符流读文件
    public static void main(String[] args) throws IOException {
        Reader reader = new FileReader("./bbb.txt");
        while (true) {
            int ret = reader.read();

            if(-1 == ret) {
                break;
            }
            char a = (char) ret;
            System.out.print(a);
        }
        reader.close();
    }

}
